package com.clusterswisdom.horn.api.tmall.action.scitem.ThreadOfStore;

import java.util.HashMap;

/**
 * 将需要同步到天猫区域库存中的数据补全，并同步到天猫区域库存中
 * @author Jin_tian
 *
 */
public class SychroToTmall implements Runnable{

	private static String tableName ;
	
	public void run() {
		try {
			HashMap<String,String> caiAndId = KeepToDb.getDataFromTmall(tableName);
			
			KeepToDb.updateItemByItemId(caiAndId, tableName);
			KeepToDb ktd = new KeepToDb();
			ktd.KeepToTmall(tableName);
			ktd.initialToTmall(tableName);
			
		} catch (Exception e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
		
		
	}
	public static String getTableName() {
		return tableName;
	}
	public static void setTableName(String tableName) {
		SychroToTmall.tableName = tableName;
	}
}
